package cn.funeralobjects.upms.entity;

import lombok.Data;
import lombok.EqualsAndHashCode;
import lombok.experimental.Accessors;

import javax.persistence.Entity;
import javax.persistence.Id;
import javax.persistence.IdClass;
import javax.persistence.Table;
import java.io.Serializable;

/**
 * API 与 角色关联对象
 *
 * @author FuneralObjects
 * Create date: 2020/4/26 3:32 PM
 */
@Data
@Accessors(chain = true)
@Entity
@Table(name = "t_api_role")
@IdClass(EApiRole.class)
@EqualsAndHashCode
public class EApiRole implements Serializable {
    /**
     * 角色id
     */
    @Id
    private Integer roleId;
    /**
     * API Id
     */
    @Id
    private Integer apiId;
}
